From: | Christian Hattemer |
Date: | 22 Aug 99 at 15:10:45 |
Subject: | Re: Dynamic Database |
From: Christian Hattemer <Chris@heaven.riednet.wh.tu-darmstadt.de>
On 20-Aug-99 DonaldWM@stonelawdrive.freeserve.co.uk wrote:
> I know how to create the intuition window, gadgets, and all about C and
> C++ 's dynamic data structures, etc., but I don't know if C or C++ allow
> variables and structures to be just invented with no prior declaration. I
> have created the program sketch below to show the general idea. */
I think you want to build completely new structs which aren't declared
anywhere in the code, right?
I had a simmilar problem, I want to duplicate a struct, which is used in a
part of the program, in another function. This function shall be able to
operate on structs with different layouts, so I'm also trying to build
structs dynamically.
I first thought to pass in an array of structs describing the struct to be
built. But it's probably not possible to find out about all offsets and
allignment needs without writing a mini compiler.
I'm now also passing all offsets and the whole size also. I'll probably have
a first version of the code soon, I'll announce it here then.
Bye, Chris
Fernsehereparaturen "Do It Your Self"
* Kein Bild, normaler Ton:
Sie sitzen vor der R�ckwand Ihres Fernsehger�tes.